<template>
  <div class="tab_bar_container">
    <div class="tab_bar_wrapper">
      <div v-for="(item,index) in  items"
      :key="index"
      @click="onClick(item)" class="tp">
	  <img src="../../../public/img/首页.png" alt="">
	  {{item.title}}
	  </div>
    </div>
  </div>
</template>

<script>
export default {
  props:{
    items:{
      type:Array,
      // required:true,
      validator:function(array){
        return array.length <= 6
      }
    }
  },
  methods:{
    onClick(item){
      this.$router.push(item.path)
    }
  }
}
</script>

<style scoped>
.tab_bar_container
{
  width: 100%;
  height: 0.64rem;
 border: 1px solid red;
 background: #FFFFFF;
  position: fixed;
  bottom: 0px;
  left: 0px;
  font-size: 0.16rem;
}
.tab_bar_wrapper
{
  width: 100%;
  height: 64px;
  display: inline-flex;
  justify-content: space-around;
  align-items: center;
  
}
	.tp{
		display: flex;
		flex-direction: column;
		align-items: center;
	}
img{
	width: .25rem;
	

}
</style>